package com.study.pre.stream;

import java.util.ArrayList;
import java.util.List;

public class FilterMain {

    public static void main(String[] args) {

        List<String> list = new ArrayList<String>();
        list.add("张三丰");
        list.add("张无忌");

        list.stream().filter(name->name.startsWith("张")).filter(name->name.length()==3).forEach(name-> System.out.println(name));

    }
}
